package com.gd.deron.smartrobot.baobao.db;

import android.content.Context;
import android.database.sqlite.SQLiteDatabase;
import android.database.sqlite.SQLiteOpenHelper;

public class DatabaseDBAsrOffineHelper extends SQLiteOpenHelper {

	private static final String DB_NAME = "deron_aijia_asr.db";
	public static final String OFFLINE_TABLE_NAME = "asrOfflineTable";
	private static final String OFFLINE_TABLE = "CREATE TABLE "+OFFLINE_TABLE_NAME+" (id integer primary key autoincrement,question varchar(100),answer varchar(500))";
	/**
	 * 数据库创建的构造方法  数据库名称  deron_aijia_asr_offline.db ，版本号为1
	 * @param context
	 */
	public DatabaseDBAsrOffineHelper(Context context) {
		super(context, DB_NAME, null, 1);
	}

	/**
	 * 初始化数据库的表结构
	 */
	@Override
	public void onCreate(SQLiteDatabase db) {
		db.execSQL(OFFLINE_TABLE);
	}

	/**
	 * 数据库版本升级时调用
	 */
	@Override
	public void onUpgrade(SQLiteDatabase db, int oldVersion, int newVersion) {
		
	}
}

